package com.jvyou.mybatis.utils.file;

import java.io.InputStream;

public class ResourceFileUtils {


    public static InputStream getResourceAsStream(String path, ClassLoader classLoader) {
        return classLoader.getResourceAsStream(path);
    }

    public static InputStream getResourceAsStream(String path) {
        Thread currentThread = Thread.currentThread();
        ClassLoader classLoader = currentThread.getContextClassLoader();
        return getResourceAsStream(path, classLoader);
    }

    public static InputStream getResourceAsStream(String path, Class<?> clazz) {
        return clazz.getResourceAsStream(path);
    }

}
